package visitor;

import java.util.ArrayList;
import java.util.List;


public class Client implements IVisitable {
	
	private String name;
	private List<Commande> commandes = new ArrayList<Commande>();

	public String getName() {
		return name;
	}

	@Override
	public void accept(IVisitor visitor) {
		visitor.visit(this);
		for(Commande co : commandes) {
			co.accept(visitor);
		}
	}
	
	public void addCommande(Commande c) {
		this.commandes.add(c);
	}
	
	public List<Commande> getCommandes() {
		return commandes;
	}
	
	public Client(String name) {
		this.name = name;
	}
	
	
}
